The present invention pertains to computer cards and more particularly to a smart host bus adapter for PC Cards.
PC Cards are credit card size devices that are designed to add functionality to portable equipment and personal computer (PC) systems. Originally the PC Cards were memory cards that were typically implemented as virtual floppy disks. Now PC Cards come in a wide variety of memory and input/output (I/O) devices and are designated as 16-bit PC Cards or as CardBus PC Cards.
PC Cards are often multi-functional type devices. The interface to the host system requires several layers of software and hardware that allow cards to be inserted and removed without turning off power to the computer. When installed, the functions on the PC Card are usually automatically included in the PC system without any need for user intervention.
PC Card hardware and software are designed to operate in the PC environment. A PC is a personal computer that is compatible with the original IBM PC and IBM PC/AT computers. The PC architecture employs a single host and an expansion bus or busses for input and output (I/O) operations. The first IBM PC had an I/O bus that evolved into the Industry Standard Architecture (ISA) bus. Current PC practices require an ISA I/O expansion bus which has a peripheral interrupt controller (PIC) function inside the ISA interface for handling all interrupts and a 8237 Direct Memory Access Controller (DMAC) function to perform third party direct memory access (DMA) transfers. ISA bus transfers are limited to one byte or to one 16-bit word at a time.
Higher performance PC systems include a hierarchy of expansion busses to interface to the system a wide variety of peripherals with differing levels of performance. Computer busses are interconnected by means of bridge devices that allow the busses to communicate with each other. In operating environments where it is necessary to expeditiously transfer large blocks of data between multiple subsystems, the PC industry has adopted the Peripheral Component Interconnect (PCI) expansion bus. The PCI bus has a throughput that is about twenty times that of the ISA bus. The high throughput is achieved through a higher clock rate and the use of burst transfers of multiple words at a rate of one double word transfer per clock cycle.
PCI interrupts do not directly map into the PC architecture. In PC systems that incorporate the PCI bus, PCI interrupts and interrupts from agents located on the PCI bus are routed to the ISA interface function. This procedure allows the single host processor to handle interrupts in the traditional manner to assure compatibility with legacy software. The PCI bus allows multiple processors, but only one host, on a single bus.
The 16-bit PC Card is an extension of the ISA bus. Legacy 16-bit PC Cards are designed to operate in the PC environment. A 16-bit PC Card must generate an interrupt or a DMA request to initiate data transfers on a system I/O bus. Access time for most cards is optimized for the ISA bus I/O read which requires three ISA clock cycles or approximately twelve PCI bus cycles. Legacy 16-bit PC Cards can transfer no more than one 16-bit word for each access.
Newer CardBus PC Cards are extensions of the PCI bus. Response time of a CardBus PC Card for a write of one double word is a minimum of two PCI bus cycles. A read requires a minimum of one more clock than a write. CardBus PC Cards can function as initiators (bus masters) or as targets (slaves) to transfer data. Target only cards operate in a manner similar to the 16-bit PC Card. While there is no specified DMA procedure for the PCI environment, PCI agents that can perform as initiators can execute DMA transfers.
The PC Card architecture provides a "plug and play" capability that simplifies the interfaces with PC configurations for various PC users. PC Cards can be added to or removed from the host system without having to reboot. The physical interface between the PC Card and the system consists of a socket for mechanical support and a host bus adapter (HBA) to provide an electrical interface.
The software includes three levels of software interfaces: Socket Services, Card Services and the individual PC Card device drivers. Socket Services is a low level interface that masks the actual hardware implementation from the vendor's PC Card device driver. The software recognizes status changes in the socket such as insertion or removal of a PC Card and prevents the device driver from having to interface to a specific HBA.
Card services is an interface between socket services and the configuration and event notification functions of the device driver. It automatically provides the management of system resources such as mapping of the function into address space, assignment of direct memory access (DMA) resources and assignment of interrupts. After configuration the device driver provides for run-time access to the resources on the PC Card by applications and the operating system (OS).
Normally the HBA is connected to an expansion bus to provide interfaces or slots for one or two PC Cards. For systems in which the HBA interfaces to the PCI bus the HBA must also provide an interrupt interface to the ISA bus to provide compatibility for 16-bit PC Cards. The I/O-type PC Card has one interrupt line that is mapped into the ISA interrupt structure by a conventional HBA. (Client drivers for some legacy 16-bit PC Cards expect to use a specific ISA interrupt.)
The ISA interface has a peripheral interrupt controller (PIC) function for interrupt handling. There are fifteen interrupts available to the system. In a typical system as many as eleven of the interrupts are preassigned. Some ISA interrupts can be shared while others can not. Typically the PCI interrupts are shared with the ISA interrupts. The PIC requires I/O transactions with the host processor that incur long latencies on the PCI bus for each bus access.
In order to transfer data to the system from an I/O capable PC Card (one that does not have bus master capability), the card must initiate the transfer with an interrupt. A data transfer between a PC Card and any other asset must be routed through the system memory of the system host processor. What seems to be a simple transfer of data between agents on the bus requires multiple, bandwidth inefficient bus accesses that cannot be posted. A bridge can accept write data from one bus and acknowledge reception to that bus to free it to perform other transactions. The bridge temporarily stores, or posts, the data until it can be written to the next bus.
In systems that have shared interrupts and multiple bus mastering processors, the single host presents a bottleneck. Interrupt handling by a single host severely impacts the efficient use of the PCI bus.
Present HBA implementations have limited data transfer operations. The PCI bus does not support an ISA-style DMA because it cannot perform fly-by (simultaneous read and write) transfers that are required to interface with the legacy DMAC. These implementations also limit the number of HBAs that can be accommodated in a system.
Accordingly, it would be advantageous to have a smart host bus adapter for PC Cards that gives a legacy card in a Smart HBA slot the same level of performance as a PCI bus master without putting a processor in the HBA, plus eliminate transaction latencies that are caused by transactions that cannot be posted.